package org.jeecg.modules.demo.allvipcard.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import org.jeecg.common.api.vo.Result;
import org.jeecg.modules.demo.allvipcard.entity.AllVipcard;
import org.jeecg.modules.demo.couponmanagement.entity.CouponManagement;

import java.util.List;
import java.util.Map;

/**
 * @Description: 全部贵宾卡
 * @Author: jeecg-boot
 * @Date: 2022-01-11
 * @Version: V1.0
 */
public interface IAllVipcardService extends IService<AllVipcard> {

    int getCount(String vipId);

    /**
     * 发卡（不包含生成二维码）
     */
    Result<?> setIssuing(String vipId, String stockIds, Integer num, String storeId);

    /**
     * 发卡（不包含生成二维码）
     */
    Result<?> setIssuing4Stock(String vipId, String memberIds, Integer num, String storeId);

    /**
     * 查询已下发贵宾卡数量
     *
     * @return
     */
    String getGrantedCardQty(String storeId);

    IPage<CouponManagement> queryCouponList(Page<CouponManagement> page, Map<String, Object> params);

    List<CouponManagement> listCouponsByVipId(String vipId, String storeId);
}
